<!DOCTYPE html>
<html>
<head>
    <title>申请表打印</title>
<#include "../../common/common.ftl"/>
</head>
<body>
<div class="layui-fluid">
    <div class="layui-card">
        <div class="layui-card-body" style="height: 730px;">
            <div class="layui-tab layui-tab-brief" id="printChoose" >
                <ul class="layui-tab-title printChoose">
                    <li class="layui-this"
                        source="/pdf/print/housePersonForPropertyPrint?houseId=${(house.id)!}">《物业费减免申请表》
                    </li>
                </ul>
            </div>
            <iframe id="printIframe" style="width: 100%;height: 99%;"></iframe>
        </div>
    </div>
</div>
<script src="/layui/layui.js" charset="utf-8"></script>
<script>
    layui.config({
        base: '/modules/' //静态资源所在路径
    }).use(['jquery','element'], function () {
        var $ = layui.jquery,element = layui.element;

        function openPdf(source) {
            var url = source + "#toolbar=0";
            $("#printIframe").attr("src", url);
        }

        $(".printChoose li").click(function () {
            var source = $(this).attr("source");
            openPdf(source);
        });
        openPdf($(".printChoose li[class='layui-this']").attr("source"));
    })
</script>
</body>
</html>